<!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>H+ 后台主题UI框架 - 空白页</title>
    <meta name="keywords" content="">
    <meta name="description" content="">

    <link rel="shortcut icon" href="favicon.ico">  <link href="__STATIC__/layout/css/bootstrap.min.css?v=3.3.6" rel="stylesheet">
    <link href="__STATIC__/layout/css/font-awesome.css?v=4.4.0" rel="stylesheet">
     <link href="__STATIC__/layout/css/plugins/summernote/summernote.css" rel="stylesheet">
    <link href="__STATIC__/layout/css/plugins/summernote/summernote-bs3.css" rel="stylesheet">
     <link rel="stylesheet" type="text/css" href="__STATIC__/layout/css/plugins/webuploader/webuploader.css">
    <link rel="stylesheet" type="text/css" href="__STATIC__/layout/css/demo/webuploader-demo.css">
    <!-- jqgrid-->
    <link href="__STATIC__/layout/css/animate.css" rel="stylesheet">
    <link href="__STATIC__/layout/css/style.css?v=4.1.0" rel="stylesheet">
    <link href="__STATIC__/layout/css/plugins/sweetalert/sweetalert.css" rel="stylesheet">
    <link href="__STATIC__/layout/css/gyq.css" rel="stylesheet">
    <link rel="stylesheet" href="__STATIC__/layout/css/demo.css" type="text/css">
</head>

<body style="color:#333;padding:3px;" class="x_sorll">
    <!-- 标题 -->
    <div class="page-heade">
      <h2 class="title_color text-center">常规促销申请</h2>
    </div>
    <!-- 标题 -->
    <div class="form-inline">
    <form action="">
      <table class="tab-content table-bordered table" border="1">
      <tr>
        <td><button class="btn-info btn" id="wanzheng" type="button" style="margin-right: 15px">导出Excel完整版</button><button class="btn btn-info">导出Excel打印版</button></td>
      </tr>
      </table>
    
      <table class="table row-margin-top table-bordered bud_hei">
        {if condition="($flagfb eq 1) or ($flaghx eq 1) "}
          <tr class="warning">
           <th colspan="8"><!--<label for="" class="form-label font-bold">当前的核查任务通知书:</label><a href="javascript:;">201703230047</a>-->
             {if condition="$flaghx eq 1"}
           <label for="" class="form-label font-bold" style="margin-left: 15px">当前的销售费用核销:</label>{volist name="hx" id="h"}<a href="{:url('Tihexiao/view')}?id={$h.id}">{$h.sn}</a>&nbsp;{/volist}
            {/if}
           {if condition="$flagfb eq 1"}
          
            <label for="" class="form-label font-bold" style="margin-left: 15px">反馈表:</label><a href="{:url('Tifeedback/view')}?id={$fb.id}">{$fb.no}</a>
           {/if}
          
           </th>
          </tr>
        {/if}
         <tr>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >主题</label></td>
             <td colspan="7" class="font-bold">{$apply.title}</td>
          </tr>
          <tr>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >编号</label></td>
             <td>{$apply.no}</td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >原申请编号</label></td>
             <td>{if condition="$apply.yuanno neq ''"}<a href="{:url('apply_de')}?aid={$apply.yuanid}">{$apply.yuanno}</a>{else/}无 {/if}</td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >修改后编号</label></td>
              <td>{if condition="$apply.nextno neq ''"}<a href="{:url('apply_de')}?aid={$apply.nextid}">{$apply.nextno}</a>{else/}无 {/if}</td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >状态</label></td>
             <td>{$apply.zhuangtai}</td>
          </tr>
           <tr>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >申请人</label></td>
             <td><a href="javascript:;">{$apply.cname}({$apply.job_name})</a></td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >申请人部门</label></td>
             <td>{$apply.de_name}</td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >申请时间</label></td>
             <td>{$apply.created_on}</td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >经销商性质</label></td>
             <td>经销</td>
          </tr>
           <tr>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >经销商名称</label></td>
             <td><span class="font-bold">{$apply.jingxiao} <a href="{:url('Commonti/jxsyj')}?aid={$aid}" class="J_menuItem"><span style="display: none;">经销商决策信息</span><span class="glyphicon glyphicon-zoom-in fangda" aria-hidden="true"></span></a></span></td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >所属分区</label></td>
             <td>{$apply.fenqu}</td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >所属省份</label></td>
             <td>{$apply.sheng}</td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label" >所属城市</label></td>
             <td>{$apply.shi}</td>
          </tr>
      </table>
       <table class="table row-margin-top table-bordered text-center bud_hei">
         <thead>
          <tr class="info">
             <th class="text-center" rowspan="2">状态</th>
            
             <th class="text-center" rowspan="2">序号</th>
            <th class="text-center"  rowspan="2">明细编号</th>
            <th class="text-center" rowspan="2">系统名称</th>
            <th class="text-center" rowspan="2">负责人</th>
            <th class="text-center" rowspan="2">网点名称</th>
            <th class="text-center" rowspan="2">产品系列</th>
            <th class="text-center">促销产品</th>
            <th class="text-center" rowspan="2">原促销执行时间</th>
            <th class="text-center" rowspan="2">异动促销执行时间</th>
            <th class="text-center" rowspan="2">预计核销时间</th>
            <th class="text-center" rowspan="2">异动后核销时间</th>
            <th class="text-center" rowspan="2">异动原因</th>
            <th class="text-center" rowspan="2">取消原因</th>
             <th class="text-center" colspan="2">预计销售量</th>
             <th class="text-center" colspan="2">实际销量</th>
             <th class="text-center" rowspan="2">销售达成率</th>
             <th class="text-center" rowspan="2">需补差销售量</th>
             <th class="text-center" colspan="12">折价幅度</th>
             <th class="text-center" colspan="9">三级费用科目</th>
            <th class="text-center" rowspan="2">费用支付方式</th>
            <th class="text-center" rowspan="2">费用小计(元)</th>
            <th class="text-center" rowspan="2">预计费用率</th>
            <th class="text-center" rowspan="2">基准销量</th>
            <th class="text-center" rowspan="2">预计ROI</th>
            <th class="text-center" rowspan="2">备注</th>
            <th class="text-center" rowspan="2">费用计入部门</th>
           
            <th class="text-center" rowspan="2">费用计入方案</th>
            
          </tr>
           <tr class="info">
            <th class="text-center">单品</th>
            <th class="text-center">预计数量</th>
            <th class="text-center">预计销售额</th>
            <th class="text-center">实际数量</th>
            <th class="text-center">实际销售额</th>
            <th class="text-center">标准出厂价</th>
            <th class="text-center">经销商原供货价</th>
            <th class="text-center">经销商现供货价</th>
            <th class="text-center">经销商折价幅度</th>
            <th class="text-center">总折价金额(元)</th>
            <th class="text-center">经销商毛利率</th>
            <th class="text-center">网点正常供货价</th>
            <th class="text-center">网点促销供货价</th>
            <th class="text-center">价幅度</th>
            <th class="text-center">总折价金额(元)</th>
            <th class="text-center">原零售价</th>
            <th class="text-center">活动期零售价</th>
            <th class="text-center">已核销金额(元)</th>
            <th class="text-center">费用名称</th>
            <th class="text-center">异动前实际投入费用(元)</th>
            <th class="text-center">未税费用金额(元)(申请金额/批复金额/反馈金额)</th>
            <th class="text-center">是否增值税(可抵扣)</th>
            <th class="text-center">税率</th>
            <th class="text-center">含税费用金额(元)</th>
            <th class="text-center">实际投入费用(元)</th>
            <th class="text-center">描述</th>
        </tr>
         </thead>

        {volist name="applynet" id="vo"}
          {volist name="applyde" id="vo1" key="j"}
              {if condition="$vo.net_id eq $vo1.net_id"}
                <tr class="text-center" {if condition="$vo1.tag eq 1"} style="color:green;" {/if}>
                  <input type="hidden" name="did[]" value="{$vo1.did}"/>
                  <td>
                    {switch name="$vo1.tag" }
                         {case value="0"}
                          正常
                        {/case}
                         {case value="1"}
                          异动
                        {/case}
                         {case value="2"}
                          取消
                        {/case}
                    {/switch}
                  </td><td>{$j}{if condition="$vo1.is_bu eq 1"}<span class="colorRed duigou" title="此单申请时间在活动开始时间之后">补单</span>{/if}</td>  
                  <td><a href="{:url('dataview')}?did={$vo1.did}" class="J_menuItem" title="{$apply.no}"> {$vo1.no}-{$vo1.detail_no}</a><a href="{:url('Commonti/decisionb')}?did={$vo1.did}"  class="J_menuItem"><span style="display: none;">决策信息</span><span class="glyphicon glyphicon-zoom-in fangda" aria-hidden="true" style="display: inline-block;"></span></a></td>
                  <td>{$vo1.xitong}</td><td>{$vo1.fuzeren}</td>
                   <td>{$vo1.net}<a href="{:url('Commonti/netyj')}?did={$vo1.did}" class="J_menuItem"><span style="display: none;">网点决策依据</span><span class="glyphicon glyphicon-zoom-in fangda" aria-hidden="true" style="display: inline-block;"></span></a></td>
                    <td>{$vo1.series_name}<a href="{:url('Commonti/seriosroi')}?did={$vo1.did}" class="J_menuItem"><span style="display: none;">ROI决策信息</span><span class="glyphicon glyphicon-zoom-in fangda" aria-hidden="true" style="display: inline-block;"></span></a></td>
                     <td><span class="glyphicon glyphicon-warning-sign jinchang" aria-hidden="true" title="此条码在申请时未进场"></span>{$vo1.pro_name}<a href="{:url('Commonti/productroi')}?did={$vo1.did}" class="J_menuItem"><span style="display: none;">ROI决策信息</span><span class="glyphicon glyphicon-zoom-in fangda" aria-hidden="true" style="display: inline-block;"></span></a></td>
                    {if condition="$vo1.tag eq 1"}
                       <td>{$vo1.yuanstart}<br>{$vo1.yuanend}</td> <td>{$vo1.start_time} <br>{$vo1.end_time}</td>
                       <td>{$vo1.yuanhexiao}</td><td>{$vo1.hexiao_time}</td>
                    {else/}
                        <td>{$vo1.start_time} <br>{$vo1.end_time}</td> <td>&nbsp;</td>
                        <td>{$vo1.hexiao_time}</td><td>&nbsp;</td>

                    {/if}
                    <td>{$vo1.ydreason}</td><td>{$vo1.cancel_reason}</td>
                     <td class="num2">{$vo1.sell_num}</td><td class="num2">{$vo1.xiaoshoue}</td><td class="num2">{$vo1.fb_boxnum}</td>
                     <td class="num2">{$vo1.shijixiaoshoue}</td><td ><span class="num2">{$vo1.xiaoliang}</span>%</td><td class="num2">{$vo1.bucha}</td>
                     <td ><span class="num2">{$vo1.factory}</span>元/{$vo1.unit}</td><td ><span class="num2">{$vo1.yuan_price}</span>元/{$vo1.unit}</td>
                     <td ><span class="num2">{$vo1.now_price}</span>元/{$vo1.unit}</td>
                     <td><span class="num2">{$vo1.zhejia}</span>%</td><td class="num2">{$vo1.jxscha}</td><td ><span class="num2">{$vo1.maoli}</span>%</td>
                      <td ><span class="num2">{$vo1.wangdian_yuan}</span>元/{$vo1.unit}</td>
                      <td {if $vo1.netout==1} style="background: red;" {/if}><span class="num2">{$vo1.wangdian_price}</span>元/{$vo1.unit}</td> 
                     <td ><span class="num2">{$vo1.wangdian_zhejia}</span>%</td> <td class="num2">{$vo1.netcha}</td>
                     <td ><span class="num2">{$vo1.lingshou_price}</span>元/{$vo1.unit}</td> <td {if $vo1.huodongout==1} style="background: red;" {/if}><span class="num2">{$vo1.huodong_price}</span>元/{$vo1.unit}</td>
                      <td class="num2">{$vo1.hexiao}</td><td>{$vo1.feiyong3}</td><td class="num2">{$vo1.yuanzonge}</td>
                      <td ><span class="num2">{$vo1.zonge} </span>/<span class="num2">{$vo1.pifuzonge}</span>/<span class="num2">{$vo1.fankuijine}</span></td>
                      <td>{if $vo1.dikou1}{if condition="$vo1.dikou1 eq 1"}可{else/}否{/if}{else/}{if condition="$vo1.dikou eq 1"}可{else/}否{/if}{/if}</td> <td ><span class="num2">{if $vo1.fb_shuilv}{$vo1.fb_shuilv}{else/}{$vo1.shuilv}{/if}</span>%</td>
                       <td class="num2">{if $vo1.fankuihanshui}{$vo1.fankuihanshui}{else}{$vo1.hanshui}{/if}</td>
                        <td class="num2">{if $vo1.fb_shijitourufeiyong}{$vo1.fb_shijitourufeiyong}{else}{$vo1.yjsjtrfy}{/if}</td><td>{$vo1.remark}</td><td>{$vo1.zffs}</td>
                       <td class="num2">{if $vo1.fb_shijitourufeiyong}{$vo1.fb_shijitourufeiyong}{else}{$vo1.yjsjtrfy}{/if}</td><td><span class="num2">{$vo1.yujifeiyonglv}</span>%</td><td class="num2">{$vo1.totalBenchmarkSales}</td>
                        <td><span class="num2">{$vo1.yujiroi}</span>%</td><td>{$vo1.beizhu}</td><td>{$vo1.de_name}</td>
                        <td>{$vo1.jrfa}</td>
                </tr>
              {/if}
          {/volist}
           <tr class="font-bold text-right">
			 <td colspan="6">小计</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td class="num2">{$vo.sellnums}</td>
          <td class="num2">{$vo.xiaoshoues}</td>
           <td class="num2">{$vo.fannums}</td>
            <td class="num2">{$vo.fanxiaoshoues}</td>
            <td ><span class="num2">{$vo.dachenglv}</span>%</td> <td class="num2">{$vo.buchas}</td>
              <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td> <td class="num2">{$vo.jxscha}</td>
           <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td><td class="num2">{$vo.netcha}</td>
           <td>&nbsp;</td><td>&nbsp;</td>
            <td class="num2">{$vo.hexiaos}</td>
             <td>&nbsp;</td>
          <td>&nbsp;</td>
           <td ><span class="num2">{$vo.zonges} </span>/<span class="num2">{$vo.pifuzonges}</span>/<span class="num2">{$vo.fankuijines}</span></td>
           <td>&nbsp;</td><td>&nbsp;</td>
            <td class="num2">{if $vo.fankuihanshuis}{$vo.fankuihanshuis}{else}{$vo.hanshuis}{/if}</td>
            <td class="num2">{if $vo.fb_shijitourufeiyongs}{$vo.fb_shijitourufeiyongs}{else}{$vo.yjsjtrfys}{/if}</td>
            <td>&nbsp;</td><td>&nbsp;</td>
            <td class="num2">{if $vo.fb_shijitourufeiyongs}{$vo.fb_shijitourufeiyongs}{else}{$vo.yjsjtrfys}{/if}</td>
            <td><span class="num2">{$vo.feiyonglv}</span>%</td><td>&nbsp;</td><td><span class="num2">{$vo.yujirois}</span>%</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td>
          </tr>
        {/volist}
      <tr class="font-bold text-right">
       <td colspan="6">合计</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td class="num2">{$all.sellnums}</td>
          <td class="num2">{$all.xiaoshoues}</td>
          <td class="num2">{$all.fannums}</td>
          <td class="num2">{$all.fanxiaoshoues}</td>
          <td ><span class="num2">{$all.dachenglv}</span>%</td> <td class="num2">{$all.buchas}</td>
           <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td> <td class="num2">{$all.jxscha}</td>
           <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td><td class="num2">{$all.netcha}</td>
          <td>&nbsp;</td><td>&nbsp;</td>
            <td class="num2">{$all.hexiaos}</td>
             <td>&nbsp;</td>
          <td>&nbsp;</td>
           <td ><span class="num2">{$all.zonges} </span>/<span class="num2">{$all.pifuzonges}</span>/<span class="num2">{$all.fankuijines}</span></td>
           <td>&nbsp;</td><td>&nbsp;</td>
           <td class="num2">{if $all.fankuihanshuis}{$all.fankuihanshuis}{else}{$all.hanshuis}{/if}</td>
            <td class="num2">{if $all.fb_shijitourufeiyongs}{$all.fb_shijitourufeiyongs}{else}{$all.yjsjtrfys}{/if}</td>
            <td>&nbsp;</td><td>&nbsp;</td>
            <td class="num2">{if $all.fb_shijitourufeiyongs}{$all.fb_shijitourufeiyongs}{else}{$all.yjsjtrfys}{/if}</td>
            <td><span class="num2">{$all.feiyonglv}</span>%</td><td>&nbsp;</td><td><span class="num2">{$all.yujirois}</span>%</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td>
      </tr>
      
      </table>
      <table class="table row-margin-top table-bordered text-left bud_hei">
        <tr>
          <td><b>本申请中包含{$netnum} 个网点，其中{volist name="feiyongjine" id="f"} {$f.title}:<span class="num2">{$f.jine}</span>元; {/volist}
              总费用:<span class="num2">{$all.hanshuis}</span>元;总预计销量:<span class="num2">{$all.xiaoshoues}</span>元;
              总费用率:<span class="num2">{$all.feiyonglv}</span>%;总预计roi:<span class="num2">{$all.yujirois}</span>%;</b>
          </td>
        </tr>
      </table>
       <table class="table table-bordered text-left bud_hei">
            <tr class="info">
                <th class="text-left font-bold">审批意见</th>
            </tr>
            {volist name="logs" id="l"}
          <tr>
              <td>{$l.USERNAME} 审批动作：{$l.MEMO}；审批意见：{if $l.COMMENTS}{$l.COMMENTS}{else/}无{/if}(审批时间：{$l.ACTIONTIME})</td>
          </tr>
          
          {/volist}
      </table>
</form>
    </div>
    {if condition="$apply.tag eq 1"}
       <div class="SuccessImg font-bold">
        申报已异动
      </div>
    {elseif condition="$apply.tag eq 2"/}
     <div class="applyImg font-bold">
        申报已取消
      </div>

    {elseif condition="$apply.status eq 7 and $apply.tag eq ''"/}
       <div class="applyImg font-bold">
        申报已生效
      </div>
      {if condition="$flaghx neq 0"}
       <div class="SuccessImg font-bold">
        申报已核销
      </div>
      {elseif condition="$apply.is_fankui neq 0"/}
       <div class="SuccessImg font-bold">
        申报已反馈
      </div>
      {/if}
    {/if}

    <!--
    <div class="applyImg font-bold">
        申报已生效
      </div>-->
    <!-- 全局js -->
   <!-- 全局js -->
    <script src="__STATIC__/layout/js/jquery.min.js?v=2.1.4"></script>
    <script src="__STATIC__/layout/js/bootstrap.min.js?v=3.3.6"></script>
    <!-- <script src="js/plugins/metisMenu/jquery.metisMenu.js"></script> -->
    <script src="__STATIC__/layout/js/plugins/slimscroll/jquery.slimscroll.min.js"></script>
   <script src="__STATIC__/layout/js/plugins/layer/laydate/laydate.js"></script>
     <script src="__STATIC__/layout/js/plugins/sweetalert/sweetalert.min.js"></script>
         <script src="__STATIC__/layout/js/plugins/slimscroll/jquery.slimscroll.min.js"></script>
<script src="__STATIC__/layout/js/plugins/summernote/summernote.min.js"></script>
<script src="__STATIC__/layout/js/plugins/summernote/summernote-zh-CN.js"></script>
<script src="__STATIC__/layout/js/plugins/suggest/bootstrap-suggest.min.js"></script>
 <script src="__STATIC__/layout/js/common.js"></script>
  <script src="__STATIC__/layout/js/plugins/layer/layer.min.js"></script>
  <script src="__STATIC__/layout/js/contabs_sub.js"></script>
  <script type="text/javascript">
  $("#wanzheng").click(function(){
      location.href="{:url('print_det')}?aid={$aid}";
  })
      $(".num2").each(function(){
                if(!isNaN(parseFloat($(this).html())))
                 var num=parseFloat($(this).html()).toFixed(2);
                else
                    var num="0.00";
                $(this).html(num);
            })
            </script>
      
 
</body>

</html>
